#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2018 crane <crane@his-pc>
#
# Distributed under terms of the MIT license.

"""

"""

class Solution:
    """
    @param: s: A string
    @return: A string
    """
    def reverseWords(self, s):
        # write your code here
        words = s.split(' ')
        words = [ele for ele in words if ele]
        words.reverse()
        return " ".join(words)


def main():
    print("start main")

if __name__ == "__main__":
    main()
